package cn.steel.domain.dto;

import jakarta.validation.constraints.Max;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import javax.validation.constraints.Size;

@Data
public class SupplierRatingDto {
    private Long orderId;
    private Long supplierId;
    private Long userId;
    @NotNull(message = "评分不能为空")
    @Min(value = 0, message = "评分不能低于0")
    @Max(value = 5, message = "评分不能高于5")
    private Integer rating;

    @Size(max = 500, message = "评价内容不能超过500个字符")
    private String comment;

    @NotBlank(message = "订单编号不能为空")
    private String orderNo;
}